package com.jackstraw.jack_base.datasource.common.aspect.annotation;


import com.jackstraw.jack_base.datasource.common.entity.enums.DataSourceTypeEnum;
import org.springframework.core.annotation.AliasFor;
import org.springframework.stereotype.Indexed;
import org.springframework.stereotype.Service;

import java.lang.annotation.Documented;
import java.lang.annotation.ElementType;
import java.lang.annotation.Inherited;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;


@Indexed
@Service
@Inherited
@Documented
@Target({ElementType.TYPE})
@Retention(RetentionPolicy.RUNTIME)
public @interface DataSourceNameCut {

    /**
     * beanName
     *
     * @return
     */
    @AliasFor(annotation = Service.class)
    String value() default "";

    /**
     * 数据源类型
     *
     * @return
     */
    DataSourceTypeEnum dataSourceTypeEnum();

    /**
     * 数据源名称
     *
     * @return
     */
    String dataSourceName() default "";
}
